package com.youlai.boot.modules.delivery.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.youlai.boot.modules.delivery.model.Delivery;
import com.youlai.boot.modules.delivery.model.DeliveryForm;
import com.youlai.boot.modules.delivery.model.DeliveryVO;
import com.youlai.boot.modules.delivery.model.DeliveryPageQuery;

public interface DeliveryService extends IService<Delivery> {
    Page<DeliveryVO> getDeliveryPage(DeliveryPageQuery query);

    DeliveryVO getDeliveryById(Long id);

    Long saveDelivery(DeliveryForm form);

    void updateDelivery(DeliveryForm form);

    boolean deleteDelivery(Long id);

    Page<DeliveryVO> getProductDeliveryPage(Long productId, DeliveryPageQuery query);

    boolean saveProductDelivery(Long productId, Long deliveryId);

    boolean deleteProductDelivery(Long productId, Long deliveryId);
}